﻿@{
    ViewBag.Title = Local("HomePage");
    ViewBag.MainNav = "home";
}

@RenderPage(TPath("Views/Shared/_ServerContainer.cshtml", "wow"))

<div class="homepage-news-wrapper">
    <script type="text/javascript" src="@Url.Content("~/Scripts/slideshow.js")"></script>
	<script type="text/javascript" src="@Url.Content("~/Scripts/swfobject.js")"></script>
    <div id="slideshow" class="ui-slideshow">
        <div class="slideshow">
			<div class="slide" id="slide-0" style="background-image: url('http://cn.origin.battle.net/cms/carousel_header/249MIPWS2DZB1317028186741.jpg'); ">
			</div>

			<div class="slide" id="slide-1" style="background-image: url('http://cn.origin.battle.net/cms/carousel_header/ZWGB4XGSQ5NA1317028205669.jpg'); display: none;">
			</div>

			<div class="slide" id="slide-2" style="background-image: url('http://cn.origin.battle.net/cms/carousel_header/8AFIVDZTEAIX1317360089502.JPG'); display: none;">
			</div>

			<div class="slide" id="slide-3" style="background-image: url('http://cn.origin.battle.net/cms/carousel_header/7PM4DFU7495I1316663161405.jpg'); display: none;">
			</div>
		</div>
		<div class="paging">
			<a href="javascript:;" id="paging-0"
				onclick="Slideshow.jump(0, this);"
				onmouseover="Slideshow.preview(0);"
				class="current">
			</a>

			<a href="javascript:;" id="paging-1"
				onclick="Slideshow.jump(1, this);"
				onmouseover="Slideshow.preview(1);"
				>
			</a>

			<a href="javascript:;" id="paging-2"
				onclick="Slideshow.jump(2, this);"
				onmouseover="Slideshow.preview(2);"
				>
			</a>

			<a href="javascript:;" id="paging-3"
				onclick="Slideshow.jump(3, this);"
				onmouseover="Slideshow.preview(3);"
				>
			</a>
		</div>
		<div class="caption">
			<h3><a href="#" class="link">即将更新，勇气点数兑换荣誉点数</a></h3>
			即将更新，勇气点数兑换荣誉点数~
		</div>
		<div class="preview"></div>
		<div class="mask"></div>
    </div>
    <script type="text/javascript">
    //<![CDATA[
        $(function () {
            Slideshow.initialize('#slideshow', [
            {
                image: "http://cn.origin.battle.net/cms/carousel_header/249MIPWS2DZB1317028186741.jpg",
                desc: "即将更新，勇气点数兑换荣誉点数~",
                title: "即将更新，勇气点数兑换荣誉点数",
                url: "#",
                id: "3867250"
            },
            {
                image: "http://cn.origin.battle.net/cms/carousel_header/ZWGB4XGSQ5NA1317028205669.jpg",
                desc: "黄金战场，每天下午和晚上均有开启，15分钟后奖励更多",
                title: "每天黄金战场【双子峰&阿拉希】",
                url: "#",
                id: "3867251"
            },
            {
                image: "http://cn.origin.battle.net/cms/carousel_header/8AFIVDZTEAIX1317360089502.JPG",
                desc: "升级宝石需要专业技能的物品兑换，可以到NPC处进行兑换",
                title: "升级宝石，升级高级武器和护甲装备",
                url: "#",
                id: "3952235"
            },
            {
                image: "http://cn.origin.battle.net/cms/carousel_header/7PM4DFU7495I1316663161405.jpg",
                desc: "CTM副本全部开放，玩家可以选择进行，GM将逐步修复BUG",
                title: "CTM副本全部开放，玩家可以选择进行",
                url: "#",
                id: "3867249"
            }
        ]);

        });
    //]]>
    </script>
</div>

<div class="homepage-news-wrapper">
    <div class="featured-news">
	  	<div class="featured-news-inner">
            <div class="featured">
                <a href="@WowUrls.LogsView_WowUrl">
	                <span class="featured-img" style="background-image: url('@TPath("content/images/server.jpg", "wow")');"><span class="featured-img-frame"></span></span>
                    <span class="featured-desc">LICH魔兽私服更新日志</span>
                </a>
            </div>
            <div class="featured">
                <a href="@WowUrls.RaidersView_WowUrl?type=database">
	                <span class="featured-img" style="background-image: url('@TPath("content/images/database.jpg", "wow")');"><span class="featured-img-frame"></span></span>
                    <span class="featured-desc">魔兽世界私服新手攻略</span>
                </a>
            </div>
            <div class="featured">
                <a href="@WowUrls.Download_WowUrl">
	                <span class="featured-img" style="background-image: url('@TPath("content/images/launcher.jpg", "wow")');"><span class="featured-img-frame"></span></span>
                    <span class="featured-desc">魔兽世界私服下载中心</span>
                </a>
            </div>
            <div class="featured">
                <a href="@WowUrls.Donate_WowUrl">
	                <span class="featured-img" style="background-image: url('@TPath("content/images/dbcaccesser.jpg", "wow")');"><span class="featured-img-frame"></span></span>
                    <span class="featured-desc">LICH魔兽世界私服赞助</span>
                </a>
            </div>
            <span class="clear"></span>
        </div>
    </div>
</div>

<div class="homepage-news-wrapper">
    <div id="news-updates">
		<div id="news-updates-inner">
        @{
            var postIndex = 0;
            foreach (var thread in Threads.GetThreads(AppConfig.HomeThreadCount))
            {
                <div class="news-article @if(postIndex == 0){ postIndex = 1; <text>first-child</text> }">
                    <div class="news-article-inner">
                        <h3>
                            <a href="@thread.ThreadUrl"> @thread.Title </a>
                        </h3>
                        <div class="by-line">
                            <a href="@thread.Category.CategoryUrl">@thread.Category.CategoryName</a>
                            <span class="spacer"></span> @thread.CreateDate.ToLocalDateTimeString()
                            <a href="@thread.ThreadUrl#comments" class="comments-link">
                                @thread.PostCount
                            </a>
                        </div>
                        <div class="article-left" style="background-image: url('@thread.LogoUrl');">
                            <a href="@thread.ThreadUrl"><span class="thumb-frame"></span></a>
                        </div>
                        <div class="article-right">
                            <div class="article-summary">
                                <p>@thread.Summary</p>
                                <a href="@thread.ThreadUrl#blog" class="more">@Local("ThreadsView.More")</a>
                            </div>
                        </div>
                        <span class="clear"></span>
                    </div>
                </div>
            }
        }
        </div>
    </div>
</div>